package com.ssm.controller.system;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.servlet.ModelAndView;

import com.ssm.entity.system.Privilege;
import com.ssm.service.system.PrivilegeService;
import com.ssm.web.Page;

@Controller
@RequestMapping("system/privilege")
public class PrivilegeController {

	@Autowired
	private PrivilegeService privilegeService;
	
	@RequestMapping("list")
	public ModelAndView list(ModelAndView mav, Privilege privilege) {
		Page<Privilege> page = privilegeService.queryList(privilege);
		mav.addObject(page);
		mav.setViewName("system/privilege/list");
		return mav;
	}
}
